package com.woniu.supermarket.service.impl;

import com.woniu.supermarket.entity.PromotionCheck;
import com.woniu.supermarket.mapper.PromotionCheckMapper;
import com.woniu.supermarket.service.IPromotionCheck;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PromotionCheckImpl implements IPromotionCheck {
    @Autowired
    PromotionCheckMapper promotionCheckMapper;

    @Override
    public List<PromotionCheck> queryByPromotionId(Integer id) {
        return promotionCheckMapper.selectByPromotionId(id);
    }

    @Override
    public void add(PromotionCheck promotionCheck) {
        promotionCheckMapper.insert(promotionCheck);
    }
}
